﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using IMDTO;
using IMDAL;
using log4net;

namespace IMBL
{
    public sealed class IMBLNaturalPerson
    {
        public List<IMDTONaturalPerson> GetAllNaturalPersons()
        {
            try
            {
                IMDAL.IMDALNaturalPerson imDalNp = new IMDALNaturalPerson();
                List<IMDTONaturalPerson> IMDTOnpL = imDalNp.GetAllNaturalPersons();

                return IMDTOnpL;

            }
            catch (Exception e)
            {
                
                throw e;

            }

        }

        public List<IMDTONaturalPersonShort> GetNaturalPersonShortsByName(string filterName)
        {
            try
            {
                IMDAL.IMDALNaturalPerson imDalNp = new IMDALNaturalPerson();
                List<IMDTONaturalPersonShort> IMDTOnpL = imDalNp.GetNaturalPersonShortsByName(filterName);

                return IMDTOnpL;

            }
            catch (Exception e)
            {

                throw e;

            }

        }

        public static IMDTONaturalPerson GetNaturalPersonForMembershipUser(Guid userGuid)
        {
            try
            {
                IMDTONaturalPerson naturalPerson;
                naturalPerson = new IMDALNaturalPerson().GetNaturalPersonForMembershipUser(userGuid);
                return naturalPerson;
            }
            catch (Exception e)
            {
                throw e;
            }
        }
    }
}
